#include "stdafx.h"
#include "Thread.h"
HAWTHORN_NAMESPACE_EBGIN

Thread::Thread(thread_callback_t func)
{
	_func = func;
	_handle = (HANDLE)_beginthreadex(
		NULL,                   // default security attributes
		0,                      // use default stack size  
		_func,					// thread function name
		this,                   // argument to thread function 
		0,                      // use default creation flags 
		&_thread_id);
}

Thread::~Thread(void)
{
	CloseHandle(_handle);
}

void Thread::join()
{
}

HAWTHORN_NAMESPACE_END